import base from './base'
import SwitchNode from './switchNode.vue'

class SwitchNodeView extends base.view {
	constructor(props) {
		super(props, SwitchNode)
	}
}

class SwitchNodeModel extends base.model {


	setAttributes() {
		this.text.editable = false; // 禁止节点文本编辑
		// 设置节点宽高和锚点
		const width = 85;
		const height = 85;
		this.width = width;
		this.height = height;
		// this.anchorsOffset = [[width / 2, 0], [0, height / 2], [-width / 2, 0], [0, -height / 2],];
	}

	getNodeOutEdgeCode() {
		return "switch-line";
	}

}

export default {
	type: 'switch-node',
	model: SwitchNodeModel,
	view: SwitchNodeView
}
